using Google.ProtocolBuffers;
using micromsg.Proto;
using System;
using System.CodeDom.Compiler;
using System.Diagnostics;
using System.IO;
using System.Runtime.CompilerServices;
namespace micromsg
{
	[GeneratedCode("ProtoGen", "2.3.0.277"), DebuggerNonUserCode, CompilerGenerated]
	public sealed class OpenBottleResponse : GeneratedMessageLite<OpenBottleResponse, OpenBottleResponse.Builder>
	{
		[GeneratedCode("ProtoGen", "2.3.0.277"), DebuggerNonUserCode, CompilerGenerated]
		public sealed class Builder : GeneratedBuilderLite<OpenBottleResponse, OpenBottleResponse.Builder>
		{
			private bool resultIsReadOnly;
			private OpenBottleResponse result;
			protected override OpenBottleResponse.Builder ThisBuilder
			{
				get
				{
					return this;
				}
			}
			public override bool IsInitialized
			{
				get
				{
					return this.result.IsInitialized;
				}
			}
			protected override OpenBottleResponse MessageBeingBuilt
			{
				get
				{
					return this.PrepareBuilder();
				}
			}
			public override OpenBottleResponse DefaultInstanceForType
			{
				get
				{
					return OpenBottleResponse.DefaultInstance;
				}
			}
			public BaseResponse BaseResponse
			{
				get
				{
					return this.result.BaseResponse;
				}
				set
				{
					this.SetBaseResponse(value);
				}
			}
			public ContentBuff SmallContentBuff
			{
				get
				{
					return this.result.SmallContentBuff;
				}
				set
				{
					this.SetSmallContentBuff(value);
				}
			}
			public ContentBuff BigContentBuff
			{
				get
				{
					return this.result.BigContentBuff;
				}
				set
				{
					this.SetBigContentBuff(value);
				}
			}
			public uint VoiceLength
			{
				get
				{
					return this.result.VoiceLength;
				}
				set
				{
					this.SetVoiceLength(value);
				}
			}
			public Builder()
			{
				this.result = OpenBottleResponse.DefaultInstance;
				this.resultIsReadOnly = true;
			}
			internal Builder(OpenBottleResponse cloneFrom)
			{
				this.result = cloneFrom;
				this.resultIsReadOnly = true;
			}
			private OpenBottleResponse PrepareBuilder()
			{
				if (this.resultIsReadOnly)
				{
					OpenBottleResponse other = this.result;
					this.result = new OpenBottleResponse();
					this.resultIsReadOnly = false;
					this.MergeFrom(other);
				}
				return this.result;
			}
			public override OpenBottleResponse.Builder Clear()
			{
				this.result = OpenBottleResponse.DefaultInstance;
				this.resultIsReadOnly = true;
				return this;
			}
			public override OpenBottleResponse.Builder Clone()
			{
				if (this.resultIsReadOnly)
				{
					return new OpenBottleResponse.Builder(this.result);
				}
				return new OpenBottleResponse.Builder().MergeFrom(this.result);
			}
			public override OpenBottleResponse BuildPartial()
			{
				if (this.resultIsReadOnly)
				{
					return this.result;
				}
				this.resultIsReadOnly = true;
				return this.result.MakeReadOnly();
			}
			public override OpenBottleResponse.Builder MergeFrom(IMessageLite other)
			{
				if (other is OpenBottleResponse)
				{
					return this.MergeFrom((OpenBottleResponse)other);
				}
				base.MergeFrom(other);
				return this;
			}
			public override OpenBottleResponse.Builder MergeFrom(OpenBottleResponse other)
			{
				return this;
			}
			public override OpenBottleResponse.Builder MergeFrom(ICodedInputStream input)
			{
				return this.MergeFrom(input, ExtensionRegistry.Empty);
			}
			public override OpenBottleResponse.Builder MergeFrom(ICodedInputStream input, ExtensionRegistry extensionRegistry)
			{
				this.PrepareBuilder();
				uint num;
				string text;
				while (input.ReadTag(out num, out text))
				{
					if (num == 0u && text != null)
					{
						int num2 = Array.BinarySearch<string>(OpenBottleResponse._openBottleResponseFieldNames, text, StringComparer.get_Ordinal());
						if (num2 < 0)
						{
							this.ParseUnknownField(input, extensionRegistry, num, text);
							continue;
						}
						num = OpenBottleResponse._openBottleResponseFieldTags[num2];
					}
					uint num3 = num;
					if (num3 <= 10u)
					{
						if (num3 == 0u)
						{
							throw InvalidProtocolBufferException.InvalidTag();
						}
						if (num3 == 10u)
						{
							BaseResponse.Builder builder = BaseResponse.CreateBuilder();
							if (this.result.hasBaseResponse)
							{
								builder.MergeFrom(this.BaseResponse);
							}
							input.ReadMessage(builder, extensionRegistry);
							this.BaseResponse = builder.BuildPartial();
							continue;
						}
					}
					else
					{
						if (num3 == 18u)
						{
							ContentBuff.Builder builder2 = ContentBuff.CreateBuilder();
							if (this.result.hasSmallContentBuff)
							{
								builder2.MergeFrom(this.SmallContentBuff);
							}
							input.ReadMessage(builder2, extensionRegistry);
							this.SmallContentBuff = builder2.BuildPartial();
							continue;
						}
						if (num3 == 26u)
						{
							ContentBuff.Builder builder3 = ContentBuff.CreateBuilder();
							if (this.result.hasBigContentBuff)
							{
								builder3.MergeFrom(this.BigContentBuff);
							}
							input.ReadMessage(builder3, extensionRegistry);
							this.BigContentBuff = builder3.BuildPartial();
							continue;
						}
						if (num3 == 32u)
						{
							this.result.hasVoiceLength = input.ReadUInt32(ref this.result.voiceLength_);
							continue;
						}
					}
					if (WireFormat.IsEndGroupTag(num))
					{
						return this;
					}
					this.ParseUnknownField(input, extensionRegistry, num, text);
				}
				return this;
			}
			public OpenBottleResponse.Builder SetBaseResponse(BaseResponse value)
			{
				ThrowHelper.ThrowIfNull(value, "value");
				this.PrepareBuilder();
				this.result.hasBaseResponse = true;
				this.result.baseResponse_ = value;
				return this;
			}
			public OpenBottleResponse.Builder SetBaseResponse(BaseResponse.Builder builderForValue)
			{
				ThrowHelper.ThrowIfNull(builderForValue, "builderForValue");
				this.PrepareBuilder();
				this.result.hasBaseResponse = true;
				this.result.baseResponse_ = builderForValue.Build();
				return this;
			}
			public OpenBottleResponse.Builder MergeBaseResponse(BaseResponse value)
			{
				ThrowHelper.ThrowIfNull(value, "value");
				this.PrepareBuilder();
				if (this.result.hasBaseResponse && this.result.baseResponse_ != BaseResponse.DefaultInstance)
				{
					this.result.baseResponse_ = BaseResponse.CreateBuilder(this.result.baseResponse_).MergeFrom(value).BuildPartial();
				}
				else
				{
					this.result.baseResponse_ = value;
				}
				this.result.hasBaseResponse = true;
				return this;
			}
			public OpenBottleResponse.Builder ClearBaseResponse()
			{
				this.PrepareBuilder();
				this.result.hasBaseResponse = false;
				this.result.baseResponse_ = null;
				return this;
			}
			public OpenBottleResponse.Builder SetSmallContentBuff(ContentBuff value)
			{
				ThrowHelper.ThrowIfNull(value, "value");
				this.PrepareBuilder();
				this.result.hasSmallContentBuff = true;
				this.result.smallContentBuff_ = value;
				return this;
			}
			public OpenBottleResponse.Builder SetSmallContentBuff(ContentBuff.Builder builderForValue)
			{
				ThrowHelper.ThrowIfNull(builderForValue, "builderForValue");
				this.PrepareBuilder();
				this.result.hasSmallContentBuff = true;
				this.result.smallContentBuff_ = builderForValue.Build();
				return this;
			}
			public OpenBottleResponse.Builder MergeSmallContentBuff(ContentBuff value)
			{
				ThrowHelper.ThrowIfNull(value, "value");
				this.PrepareBuilder();
				if (this.result.hasSmallContentBuff && this.result.smallContentBuff_ != ContentBuff.DefaultInstance)
				{
					this.result.smallContentBuff_ = ContentBuff.CreateBuilder(this.result.smallContentBuff_).MergeFrom(value).BuildPartial();
				}
				else
				{
					this.result.smallContentBuff_ = value;
				}
				this.result.hasSmallContentBuff = true;
				return this;
			}
			public OpenBottleResponse.Builder ClearSmallContentBuff()
			{
				this.PrepareBuilder();
				this.result.hasSmallContentBuff = false;
				this.result.smallContentBuff_ = null;
				return this;
			}
			public OpenBottleResponse.Builder SetBigContentBuff(ContentBuff value)
			{
				ThrowHelper.ThrowIfNull(value, "value");
				this.PrepareBuilder();
				this.result.hasBigContentBuff = true;
				this.result.bigContentBuff_ = value;
				return this;
			}
			public OpenBottleResponse.Builder SetBigContentBuff(ContentBuff.Builder builderForValue)
			{
				ThrowHelper.ThrowIfNull(builderForValue, "builderForValue");
				this.PrepareBuilder();
				this.result.hasBigContentBuff = true;
				this.result.bigContentBuff_ = builderForValue.Build();
				return this;
			}
			public OpenBottleResponse.Builder MergeBigContentBuff(ContentBuff value)
			{
				ThrowHelper.ThrowIfNull(value, "value");
				this.PrepareBuilder();
				if (this.result.hasBigContentBuff && this.result.bigContentBuff_ != ContentBuff.DefaultInstance)
				{
					this.result.bigContentBuff_ = ContentBuff.CreateBuilder(this.result.bigContentBuff_).MergeFrom(value).BuildPartial();
				}
				else
				{
					this.result.bigContentBuff_ = value;
				}
				this.result.hasBigContentBuff = true;
				return this;
			}
			public OpenBottleResponse.Builder ClearBigContentBuff()
			{
				this.PrepareBuilder();
				this.result.hasBigContentBuff = false;
				this.result.bigContentBuff_ = null;
				return this;
			}
			public OpenBottleResponse.Builder SetVoiceLength(uint value)
			{
				this.PrepareBuilder();
				this.result.hasVoiceLength = true;
				this.result.voiceLength_ = value;
				return this;
			}
			public OpenBottleResponse.Builder ClearVoiceLength()
			{
				this.PrepareBuilder();
				this.result.hasVoiceLength = false;
				this.result.voiceLength_ = 0u;
				return this;
			}
		}
		public const int BaseResponseFieldNumber = 1;
		public const int SmallContentBuffFieldNumber = 2;
		public const int BigContentBuffFieldNumber = 3;
		public const int VoiceLengthFieldNumber = 4;
		private static readonly OpenBottleResponse defaultInstance;
		private static readonly string[] _openBottleResponseFieldNames;
		private static readonly uint[] _openBottleResponseFieldTags;
		private bool hasBaseResponse;
		private BaseResponse baseResponse_;
		private bool hasSmallContentBuff;
		private ContentBuff smallContentBuff_;
		private bool hasBigContentBuff;
		private ContentBuff bigContentBuff_;
		private bool hasVoiceLength;
		private uint voiceLength_;
		private int memoizedSerializedSize = -1;
		public static OpenBottleResponse DefaultInstance
		{
			get
			{
				return OpenBottleResponse.defaultInstance;
			}
		}
		public override OpenBottleResponse DefaultInstanceForType
		{
			get
			{
				return OpenBottleResponse.DefaultInstance;
			}
		}
		protected override OpenBottleResponse ThisMessage
		{
			get
			{
				return this;
			}
		}
		public BaseResponse BaseResponse
		{
			get
			{
				return this.baseResponse_ ?? BaseResponse.DefaultInstance;
			}
		}
		public ContentBuff SmallContentBuff
		{
			get
			{
				return this.smallContentBuff_ ?? ContentBuff.DefaultInstance;
			}
		}
		public ContentBuff BigContentBuff
		{
			get
			{
				return this.bigContentBuff_ ?? ContentBuff.DefaultInstance;
			}
		}
		public uint VoiceLength
		{
			get
			{
				return this.voiceLength_;
			}
		}
		public override bool IsInitialized
		{
			get
			{
				return this.hasBaseResponse && this.hasSmallContentBuff && this.hasBigContentBuff && this.hasVoiceLength && this.BaseResponse.IsInitialized && this.SmallContentBuff.IsInitialized && this.BigContentBuff.IsInitialized;
			}
		}
		public override int SerializedSize
		{
			get
			{
				int num = this.memoizedSerializedSize;
				if (num != -1)
				{
					return num;
				}
				num = 0;
				if (this.hasBaseResponse)
				{
					num += CodedOutputStream.ComputeMessageSize(1, this.BaseResponse);
				}
				if (this.hasSmallContentBuff)
				{
					num += CodedOutputStream.ComputeMessageSize(2, this.SmallContentBuff);
				}
				if (this.hasBigContentBuff)
				{
					num += CodedOutputStream.ComputeMessageSize(3, this.BigContentBuff);
				}
				if (this.hasVoiceLength)
				{
					num += CodedOutputStream.ComputeUInt32Size(4, this.VoiceLength);
				}
				this.memoizedSerializedSize = num;
				return num;
			}
		}
		private OpenBottleResponse()
		{
		}
		public override void WriteTo(ICodedOutputStream output)
		{
			int arg_06_0 = this.SerializedSize;
			string[] openBottleResponseFieldNames = OpenBottleResponse._openBottleResponseFieldNames;
			if (this.hasBaseResponse)
			{
				output.WriteMessage(1, openBottleResponseFieldNames[0], this.BaseResponse);
			}
			if (this.hasSmallContentBuff)
			{
				output.WriteMessage(2, openBottleResponseFieldNames[2], this.SmallContentBuff);
			}
			if (this.hasBigContentBuff)
			{
				output.WriteMessage(3, openBottleResponseFieldNames[1], this.BigContentBuff);
			}
			if (this.hasVoiceLength)
			{
				output.WriteUInt32(4, openBottleResponseFieldNames[3], this.VoiceLength);
			}
		}
		public override int GetHashCode()
		{
			int num = base.GetType().GetHashCode();
			if (this.hasBaseResponse)
			{
				num ^= this.baseResponse_.GetHashCode();
			}
			if (this.hasSmallContentBuff)
			{
				num ^= this.smallContentBuff_.GetHashCode();
			}
			if (this.hasBigContentBuff)
			{
				num ^= this.bigContentBuff_.GetHashCode();
			}
			if (this.hasVoiceLength)
			{
				num ^= this.voiceLength_.GetHashCode();
			}
			return num;
		}
		public override bool Equals(object value)
		{
			OpenBottleResponse openBottleResponse = value as OpenBottleResponse;
			return openBottleResponse != null && (this.hasBaseResponse == openBottleResponse.hasBaseResponse && (!this.hasBaseResponse || this.baseResponse_.Equals(openBottleResponse.baseResponse_))) && (this.hasSmallContentBuff == openBottleResponse.hasSmallContentBuff && (!this.hasSmallContentBuff || this.smallContentBuff_.Equals(openBottleResponse.smallContentBuff_))) && (this.hasBigContentBuff == openBottleResponse.hasBigContentBuff && (!this.hasBigContentBuff || this.bigContentBuff_.Equals(openBottleResponse.bigContentBuff_))) && (this.hasVoiceLength == openBottleResponse.hasVoiceLength && (!this.hasVoiceLength || this.voiceLength_.Equals(openBottleResponse.voiceLength_)));
		}
		public override void PrintTo(TextWriter writer)
		{
			GeneratedMessageLite<OpenBottleResponse, OpenBottleResponse.Builder>.PrintField("BaseResponse", this.hasBaseResponse, this.baseResponse_, writer);
			GeneratedMessageLite<OpenBottleResponse, OpenBottleResponse.Builder>.PrintField("SmallContentBuff", this.hasSmallContentBuff, this.smallContentBuff_, writer);
			GeneratedMessageLite<OpenBottleResponse, OpenBottleResponse.Builder>.PrintField("BigContentBuff", this.hasBigContentBuff, this.bigContentBuff_, writer);
			GeneratedMessageLite<OpenBottleResponse, OpenBottleResponse.Builder>.PrintField("VoiceLength", this.hasVoiceLength, this.voiceLength_, writer);
		}
		public static OpenBottleResponse ParseFrom(byte[] data)
		{
			return OpenBottleResponse.CreateBuilder().MergeFrom(data).BuildParsed();
		}
		private OpenBottleResponse MakeReadOnly()
		{
			return this;
		}
		public static OpenBottleResponse.Builder CreateBuilder()
		{
			return new OpenBottleResponse.Builder();
		}
		public override OpenBottleResponse.Builder ToBuilder()
		{
			return OpenBottleResponse.CreateBuilder(this);
		}
		public override OpenBottleResponse.Builder CreateBuilderForType()
		{
			return new OpenBottleResponse.Builder();
		}
		public static OpenBottleResponse.Builder CreateBuilder(OpenBottleResponse prototype)
		{
			return new OpenBottleResponse.Builder(prototype);
		}
		static OpenBottleResponse()
		{
			OpenBottleResponse.defaultInstance = new OpenBottleResponse().MakeReadOnly();
			OpenBottleResponse._openBottleResponseFieldNames = new string[]
			{
				"BaseResponse",
				"BigContentBuff",
				"SmallContentBuff",
				"VoiceLength"
			};
			OpenBottleResponse._openBottleResponseFieldTags = new uint[]
			{
				10u,
				26u,
				18u,
				32u
			};
			object.ReferenceEquals(micromsg.Proto.OpenBottleResponse.Descriptor, null);
		}
	}
}
